package Test07;

//static静态
/*需求:写一个JavaBean类来描述这个班级的学生
        属性:姓名、年龄、性别
        行为:学习
*/
public class test01 {
    //属性
    private String name;
    private int age;
    private String gender;
    //新增老师的名字的属性
    public static String teacherName;


    public test01() {
    }

    public test01(String name, int age, String gender) {
        this.name = name;
        this.age = age;
        this.gender = gender;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
    }

    //行为
    public void study() {
        System.out.println(name + "正在学习");
    }

    public void show() {
        System.out.println(name + ", " + age + ", " + gender + ", " + teacherName);
    }
}
